package com.cruise.game.model.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 收藏实体类
 * 
 * @author cruise
 * @date 2025-02-28
 */
@Data
@TableName("favorites")
public class Favorite implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 主键，收藏ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 关联用户ID
     */
    private Long userId;

    /**
     * 关联游戏服务ID
     */
    private Long serviceId;

    /**
     * 创建时间
     */
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createdAt;

    /**
     * 逻辑删除标记
     * 注意：数据库表中暂不存在此字段
     */
    @TableLogic
    @TableField(exist = false)
    private Integer deleted;
}
